#ifndef __LCD_H__
#define __LCD_H__

#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <sys/ioctl.h>
#include <stdint.h>
#include <sys/mman.h>
#include <fcntl.h>
#include <stdbool.h>
#include <errno.h>
#include <string.h>
#include <signal.h>
#include <pthread.h>
#include <linux/fb.h>
#include <dirent.h>
#include "datatype.h"
#include "file_link.h"
#include "touch_panel.h"

void init_lcd(struct lcd_info *lcdinfo);
void clean_screen(struct lcd_info *lcdinfo,int offsize);
void release_lcd(struct lcd_info *lcdinfo);
void scale_image(const char *jpeg_buffer, int original_width, int original_height,
                 char *scaled_buffer, int scaled_width, int scaled_height, int rgb_size);
void show_png(struct lcd_info *lcdinfo,struct img_info *pnginfo,int offsize);
void show_jpg(struct lcd_info *lcdinfo, struct img_info *jpginfo,int offsize);
void show_bmp(struct lcd_info *lcdinfo, struct img_info *bmpinfo,int offsize);
void init_display(struct lcd_info *lcdinfo,piclink head);
void change_display(struct lcd_info *lcdinfo,int y);
void lcd_input(struct lcd_info *lcdinfo,struct img_info *imginfo,int y);
void switch_display(struct lcd_info *lcdinfo,piclink head,int tp);
#endif